home *** CD-ROM | disk | FTP | other *** search
/ Technotools / Technotools (Chestnut CD-ROM)(1993).ISO / lantools / bkup / s_backsv.bat < prev    next >
DOS Batch File  |  1990-08-19  |  2KB  |  65 lines

  1. :... S_BACKSV.BAT, Craig MacPherson
  2. :    Batch routine to backup the system file server.
  3. :    Variables passed
  4. :    %1 - ALL or MOD
  5. :    %2 - Drive
  6. :    %3 - Server
  7. :    %4 - Volume
  8.  
  9. @echo off
  10. cls
  11.  
  12. :... Map backup drive to correct server and volume
  13.      map %2:=%3/%4:\
  14.  
  15.      cd \backups\backup.jbs
  16.  
  17. :... Mark Start of Job message in detailed log
  18.      call %D2%b_soj.bat SRV
  19.  
  20. :... Which backup to run Mod or Full
  21.      if %1.==. goto ALL_FILES
  22.      if %1.==MOD. goto MODIFIED_FILES_ONLY
  23.      :ALL_FILES  
  24.        set STATUS=GOOD
  25.        tbackup %2:\/s/y/la:"Server Complete backup - %4"/a/li:"files.tmp":a
  26.        if errorlevel set STATUS=BAD
  27.        goto UPDATE_LOGS
  28.  
  29.     :MODIFIED_FILES_ONLY
  30.        set STATUS=GOOD
  31.        tbackup %2:\/s/y/m/la:"Server Modified files only - %4"/a/li:"files.tmp":a 
  32.        if errorlevel set STATUS=BAD
  33.        goto UPDATE_LOGS
  34.  
  35.  
  36. :UPDATE_LOGS
  37.      :USERS_DETAILED_LOG
  38.      :... Add current tape volume to users detailed history log
  39.           copy %D2%\backups\activity.lgs\SRV.his+%D2%\backups\cur_tape.vol %D2%\backups\activity.lgs\SRV.his
  40.  
  41.      :... Add Maynard tape program output to users detailed history log
  42.           copy %D2%\backups\activity.lgs\SRV.his+files.tmp %D2%\backups\activity.lgs\SRV.his
  43.           del files.tmp>>nul:
  44.  
  45.      :... Check for skipped or corrupt files, add info to users detailed history log
  46.           call %D1%b_skip.bat SRV
  47.           goto MARK_EOJ
  48.  
  49.      :MARK_EOJ
  50.      :... Mark EOJ in users history file
  51.           call %D1%b_eoj.bat SRV
  52.  
  53.      :... Strip Form Feeds from users history file
  54.           call %D1%b_strip.bat SRV
  55.  
  56.      :SYSTEM AND USER SUMMARY LOGS
  57.      :... Add user info and status to system activity log and user summary log
  58.           call %D1%b_activ.bat BACKUP %STATUS% SRV %4 %1 
  59.  
  60.  
  61.  
  62. :END
  63.